# -*- coding: UTF-8 -*-

from application.config.redis import connect_redis, redis_json_get

data_list = [
    "16G80RX9K2",
    "16HD5400P6",
    "6Z9804000F",
    "16F8U400W9",
    "16R81G0039"
]

cn = connect_redis(3)
keys = cn.keys()
print('开始')
for key in keys:
    value = redis_json_get(3, key)
    if value.get('shopping_code') in data_list and value.get('is_prize') == 1:
        print(f'Key: {key}, Value: {value}')
print('完成')
